# Maintainer: Kyle Keen <keenerd@gmail.com>
# Contributor: Thomas Dziedzic < gostrc at gmail >
# Contributor: Jared Casper <jaredcasper@gmail.com>

pkgname=gtkwave
pkgver=3.3.115
pkgrel=1
pkgdesc='A wave viewer which reads LXT, LXT2, VZT, GHW and VCD/EVCD files'
arch=('loong64' 'x86_64')
url='http://gtkwave.sourceforge.net'
license=('GPL' 'MIT')
depends=('bzip2' 'xz' 'gtk3' 'desktop-file-utils' 'dconf')
makedepends=('gperf')
install='gtkwave.install'
source=("https://gtkwave.sourceforge.net/gtkwave-gtk3-${pkgver}.tar.gz")
sha256sums=('adb7a7c02b18ca0835a064b672f6cdc51f875c454b0189a743f2ce8b91e64aa5')

build() {
  cd gtkwave-gtk3-$pkgver

  ./configure \
    --prefix=/usr \
    --disable-tcl \
    --disable-mime-update \
    --with-gsettings \
    --enable-gtk3

  make CFLAGS="-D_LARGEFILE64_SOURCE -O"
}

package() {
  cd gtkwave-gtk3-$pkgver

  make DESTDIR="${pkgdir}" install

  install -D -m644 LICENSE.TXT \
    "$pkgdir/usr/share/licenses/gtkwave/LICENSE.TXT"
}

